package com.bwf.ip;

import java.net.InetAddress;
import java.net.UnknownHostException;

/**
 * @Version v1.0
 * @Description: TODO
 * @Author ZHANZHONGXIN
 * @Date 2022/5/26 10:25
 * @Copyright 博为峰
 */
public class InetAddressDemo {
    public static void main(String[] args) throws UnknownHostException {
        InetAddress localHost = InetAddress.getLocalHost();
        System.out.println(localHost);
        InetAddress address = InetAddress.getByName("172.20.255.74");
    }
}
